home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 4 / Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso / Applications / gdbm-1.7.3 / source / Makefile < prev    next >
Makefile  |  1994-05-21  |  6KB  |  231 lines

  1. # Generated automatically from Makefile.in by configure.
  2. #### Start of system configuration section. ####
  3.  
  4. srcdir = .
  5. VPATH = .
  6.  
  7. CC = gcc
  8.  
  9. INSTALL = /usr/bin/install -c
  10. INSTALL_PROGRAM = $(INSTALL)
  11. INSTALL_DATA = $(INSTALL) -m 644
  12.  
  13. MAKEINFO = makeinfo
  14. TEXI2DVI = texi2dvi
  15. RANLIB = ranlib
  16.  
  17. DEFS =
  18.  
  19. # Where the system [n]dbm routines are...
  20. LIBS =  -ldbm -lc
  21.  
  22. # SunOS users might wish to add '-fpcc-struct-return' to CFLAGS. see INSTALL.
  23. CFLAGS = -O
  24. LDFLAGS =
  25.  
  26. # Common prefix for installation directories
  27. prefix = /usr/local
  28. exec_prefix = $(prefix)
  29. binprefix = $(exec_prefix)
  30. manprefix = $(prefix)
  31.  
  32. # Directory in which to put libgdbm.a.
  33. libdir = $(exec_prefix)/lib
  34. # The include directory for gdbm.h and dbm.h.
  35. includedir = $(prefix)/include
  36. # Info and man directories.
  37. infodir = $(prefix)/info
  38. man3dir = $(prefix)/man/man3
  39. manext = 3
  40.  
  41. #### End of system configuration section. ####
  42.  
  43. .c.o:
  44.     $(CC) -c $(CPPFLAGS) $(DEFS) -I. -I$(srcdir) $(CFLAGS) $<
  45.  
  46. SHELL = /bin/sh
  47.  
  48. PROGS = libgdbm.a testgdbm testdbm testndbm tndbm tdbm conv2gdbm
  49.  
  50. DBM_CF = dbminit.c delete.c fetch.c store.c seq.c close.c
  51.  
  52. NDBM_CF = dbmopen.c dbmdelete.c dbmfetch.c dbmstore.c dbmseq.c \
  53.     dbmclose.c dbmdirfno.c dbmpagfno.c dbmrdonly.c
  54.  
  55. GDBM_CF = gdbmopen.c gdbmdelete.c gdbmfetch.c  gdbmstore.c gdbmclose.c \
  56.     gdbmreorg.c gdbmseq.c gdbmsync.c gdbmerrno.c gdbmexists.c gdbmsetopt.c \
  57.     bucket.c falloc.c findkey.c global.c hash.c update.c \
  58.     version.c
  59.  
  60. TEST_CF = testdbm.c testndbm.c testgdbm.c
  61.  
  62.  
  63. DBM_OF = dbminit.o delete.o fetch.o store.o seq.o close.o
  64.  
  65. NDBM_OF = dbmopen.o dbmdelete.o dbmfetch.o dbmstore.o dbmseq.o \
  66.     dbmclose.o dbmdirfno.o dbmpagfno.o dbmrdonly.o
  67.  
  68. GDBM_OF = gdbmopen.o gdbmdelete.o gdbmfetch.o  gdbmstore.o gdbmclose.o \
  69.     gdbmreorg.o gdbmseq.o gdbmsync.o gdbmerrno.o gdbmexists.o gdbmsetopt.o \
  70.     bucket.o falloc.o findkey.o global.o hash.o update.o \
  71.     version.o
  72.  
  73. TEX_F = gdbm.aux gdbm.cp gdbm.dvi gdbm.fn gdbm.ky gdbm.log gdbm.pg \
  74.     gdbm.toc gdbm.tp gdbm.vr
  75.  
  76. TEXI_F = gdbm.info
  77.      
  78. SRCS = $(DBM_CF) $(NDBM_CF) $(GDBM_CF) $(TEST_CF)
  79.  
  80. OBJS = $(DBM_OF) $(NDBM_OF) $(GDBM_OF) 
  81.  
  82. HDRS = gdbmdefs.h extern.h gdbmerrno.h systems.h dbm.h ndbm.h gdbmconst.h \
  83.     proto.h
  84.  
  85. MSCFILES = COPYING ChangeLog Makefile.in README gdbm.3 gdbm.texinfo \
  86.     gdbm.info NEWS INSTALL gdbm.proto gdbm.proto2 conv2gdbm.c \
  87.     configure configure.in alloca.c getopt.c getopt.h samp1.cc \
  88.     autoconf.h.in
  89.  
  90. DISTFILES = $(SRCS) $(HDRS) $(MSCFILES)
  91.  
  92. all: libgdbm.a
  93.  
  94. progs: $(PROGS)
  95.  
  96. install: libgdbm.a gdbm.h gdbm.info
  97.     $(INSTALL_DATA) libgdbm.a $(libdir)/libgdbm.a
  98.     $(INSTALL_DATA) gdbm.h $(includedir)/gdbm.h
  99.     $(INSTALL_DATA) $(srcdir)/gdbm.3 $(man3dir)/gdbm.3
  100.     $(INSTALL_DATA) $(srcdir)/gdbm.info $(infodir)/gdbm.info
  101.  
  102. install-compat:
  103.     $(INSTALL_DATA) $(srcdir)/dbm.h $(includedir)/dbm.h
  104.     $(INSTALL_DATA) $(srcdir/ndbm.h $(includedir)/ndbm.h
  105.  
  106. libgdbm.a: $(OBJS) gdbm.h
  107.     rm -f libgdbm.a
  108.     ar q libgdbm.a $(OBJS)
  109.     $(RANLIB) libgdbm.a
  110.  
  111. gdbm.h:    gdbm.proto gdbmerrno.h gdbm.proto2
  112.     rm -f gdbm.h
  113.     cp $(srcdir)/gdbm.proto gdbm.h
  114.     chmod +w gdbm.h
  115.     grep _ $(srcdir)/gdbmerrno.h >> gdbm.h
  116.     cat $(srcdir)/gdbm.proto2 >> gdbm.h
  117.     chmod -w gdbm.h
  118.  
  119. testgdbm: testgdbm.o libgdbm.a 
  120.     $(CC) $(LDFLAGS) -o testgdbm testgdbm.o libgdbm.a 
  121.  
  122. testdbm: testdbm.o libgdbm.a
  123.     $(CC) $(LDFLAGS) -o testdbm testdbm.o libgdbm.a
  124.  
  125. tdbm: testdbm.o libgdbm.a
  126.     $(CC) $(LDFLAGS) -o tdbm testdbm.o $(LIBS)
  127.  
  128. testndbm.o: testndbm.c
  129.     $(CC) -c -I. -I$(srcdir) $(CFLAGS) $(DEFS) -DGNU $(srcdir)/testndbm.c
  130.  
  131. testndbm: testndbm.o libgdbm.a
  132.     $(CC) $(LDFLAGS) -o testndbm testndbm.o libgdbm.a
  133.  
  134. tndbm.o: testndbm.c
  135.     cp $(srcdir)/testndbm.c ./tndbm.c
  136.     $(CC) -c -I. -I$(srcdir) $(CFLAGS) $(DEFS) ./tndbm.c
  137.     rm -f ./tndbm.c
  138.  
  139. tndbm: tndbm.o libgdbm.a
  140.     $(CC) $(LDFLAGS) -o tndbm tndbm.o $(LIBS)
  141.  
  142. conv2gdbm: conv2gdbm.o libgdbm.a 
  143.     $(CC) $(LDFLAGS) -o conv2gdbm conv2gdbm.o $(LIBS) libgdbm.a 
  144.  
  145. lintgdbm: 
  146.     lint $(DEFS) $(LFLAGS) $(DBM_CF) $(NDBM_CF) $(GDBM_CF) testgdbm.c
  147.  
  148. TAGS: $(SRCS)
  149.     etags $(SRCS)
  150.  
  151. info: gdbm.info
  152.  
  153. gdbm.info:
  154.     $(MAKEINFO) $(srcdir)/gdbm.texinfo
  155.  
  156. dvi: gdbm.dvi
  157.  
  158. gdbm.dvi:
  159.     $(TEXI2DVI) $(srcdir)/gdbm.texinfo
  160.  
  161. clean:
  162.     rm -f $(PROGS) $(TEX_F) *.o core junk*
  163.  
  164. mostlyclean: clean
  165.  
  166. distclean: clean
  167.     rm -f Makefile autoconf.h config.status gdbm.h $(TEXI_F) *~
  168.  
  169. realclean: distclean
  170.     rm -f TAGS
  171.     -rm -f \
  172.       `sed -n 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/gdbm-\1/p' \
  173.         version.c`.tar.gz
  174.  
  175. dist:
  176.     echo \
  177.       `sed -n 's/.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*/gdbm-\1/p' \
  178.         version.c` > .fname
  179.     rm -rf `cat .fname`
  180.     mkdir `cat .fname`
  181.     ln $(DISTFILES) `cat .fname`
  182.     tar chf `cat .fname`.tar `cat .fname`
  183.     gzip `cat .fname`.tar
  184.     rm -rf `cat .fname` .fname
  185.  
  186. # dbm files
  187. dbminit.o:    autoconf.h gdbmdefs.h proto.h extern.h gdbmerrno.h
  188. delete.o:    autoconf.h gdbmdefs.h proto.h extern.h
  189. fetch.o:    autoconf.h gdbmdefs.h proto.h extern.h
  190. store.o:    autoconf.h gdbmdefs.h proto.h extern.h
  191. seq.o:        autoconf.h gdbmdefs.h proto.h extern.h
  192.  
  193. # ndbm files
  194. dbmopen.o:    autoconf.h gdbmdefs.h extern.h gdbmerrno.h
  195. dbmdelete.o:    autoconf.h gdbmdefs.h extern.h
  196. dbmfetch.o:    autoconf.h gdbmdefs.h extern.h
  197. dbmstore.o:    autoconf.h gdbmdefs.h extern.h
  198. dbmseq.o:    autoconf.h gdbmdefs.h extern.h
  199. dbmclose.o:    autoconf.h gdbmdefs.h systems.h
  200. dbmpagfno.o:    autoconf.h gdbmdefs.h extern.h
  201. dbmdirfno.o:    autoconf.h gdbmdefs.h extern.h
  202.  
  203.  
  204. # gdbm files
  205. gdbmclose.o:    autoconf.h gdbmdefs.h 
  206. gdbmdelete.o:    autoconf.h gdbmdefs.h gdbmerrno.h 
  207. gdbmfetch.o:    autoconf.h gdbmdefs.h gdbmerrno.h 
  208. gdbmopen.o:    autoconf.h gdbmdefs.h gdbmerrno.h 
  209. gdbmreorg.o:    autoconf.h gdbmdefs.h gdbmerrno.h extern.h
  210. gdbmseq.o:    autoconf.h gdbmdefs.h 
  211. gdbmstore.o:    autoconf.h gdbmdefs.h gdbmerrno.h 
  212.  
  213. # gdbm support files
  214. bucket.o:    autoconf.h gdbmdefs.h
  215. falloc.o:    autoconf.h gdbmdefs.h
  216. findkey.o:    autoconf.h gdbmdefs.h
  217. global.o:    autoconf.h gdbmdefs.h gdbmerrno.h 
  218. hash.o:        autoconf.h gdbmdefs.h
  219. update.o:    autoconf.h gdbmdefs.h
  220. version.o:
  221. extern.h:
  222. gdbmdefs.h:    gdbmconst.h systems.h
  223.     touch gdbmdefs.h
  224.  
  225. # other programs
  226. testgdbm.o:    autoconf.h gdbmdefs.h extern.h gdbmerrno.h systems.h
  227. testdbm.o:    autoconf.h
  228. testndbm.o:    autoconf.h ndbm.h
  229. tdbm.o:        autoconf.h
  230. conv2gdbm.o:    autoconf.h gdbm.h
  231.